<template>
  <view>
    <view>
    </view>
    <view class="neirong" v-if="type==='A'">
      <view class="shangP" :key="item.id" v-for="item in scspList">
        <view>
          <image :src="item.imgSrc"></image>
        </view>
        <view class="text">
          <text>{{item.name}}</text><br>
          <text>{{item.money}}￥</text>
        </view>
      </view>
    </view>
  </view>
</template>

<script>
export default {
  name:'wdgz',
  data() {
    return {
      type:'A',
      scspList:[]
    }
  },
  created() {
      let _this = this;
      uni.request({
        url: "http://123.57.67.148:3000/mock/42/PostWdgzData",
        method: "post",
        success(res) {
          _this.scspList = res.data.data;
          console.log(_this.scspList)
        }
      });
    }
}
</script>

<style scoped>
.neirong{
  width: 100%;
  display: flex;
  flex-direction: column;
}
.shangP{
  width: 100%;
  /* height: 8rem; */
  display: flex;
  /* margin: auto; */
  background-color: rgb(248, 248, 248);
  justify-content: flex-start;
  border-bottom: 1px solid gray;
  /* margin: 1rem 0; */
}
.shangP image{
  width: 8rem;
  height: 6rem;
}
.text{
  padding-left: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
}
</style>
